<?php
namespace app\common\model;
use think\Model;
use think\model\concern\SoftDelete;

class InstallDevices extends Model
{
    use SoftDelete;
    protected $autoWriteTimestamp = true;
    protected $deleteTime = 'delete_time';
    
    public function cars(){
        return $this->hasOne('Cars','car_id','car_id')->field('car_id,car_sn,cardcode,equipment_id,sim_id');
    }
    
    public function terminal(){
        return $this->hasOne('Terminal','id','tid');
    }
    
    public function installUser(){
        return $this->hasOne('InstallUser','id','user_id');
    }
    
  
}